package com.itao.springboot.controller;

import com.itao.springboot.annotation.ExcelExport;
import com.itao.springboot.vo.ExcelVo;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

/**
 * @author sjt
 * @Date 2024/12/9 10:22
 */
@RestController
public class ExcelController {

    @GetMapping("/export")
    @ExcelExport(value = "用户")
    public List<ExcelVo> export(){
        ArrayList<ExcelVo> objects = new ArrayList<>();
        objects.add(new ExcelVo("sjt", 18));
        objects.add(new ExcelVo("syt", 19));
        return objects;
    }


}
